#ifndef TEST_CLIENT_H_
#define TEST_CLIENT_H_

#include <string>
#include "../ConnectMsg.h"
#include "ClientProcess.h"

class TestClient:public ClientProcess
{
public:
	TestClient();
	virtual ~TestClient();
	virtual int connect(const std::string& ip, int port);
	virtual int close();
	virtual int writeProcess(void*);
	virtual int readProcess(void*);
	virtual int getfd(){return m_fd;}
protected:
	int m_fd;
	unsigned char m_buffer[256];
	size_t m_size;
	size_t m_usedSize;
private:
	TestClient(const TestClient&);
	TestClient& operator=(const TestClient&);
	
	std::string generateUsername();
	int generateMsg(unsigned char* buffer, ClientMsg msg);
};

#endif
